package cn.edu.xmu.oomall.order.model.vo;

import cn.edu.xmu.oomall.core.model.VoObject;
import cn.edu.xmu.oomall.order.microservice.vo.SimpleUserRetVo;
import cn.edu.xmu.oomall.order.model.bo.Order;

import java.time.LocalDateTime;

public class AfterSaleOrderRetVo implements VoObject {

    private long id;
    private String orderSn;
    private SimpleUserRetVo customer;
    private ShopRetVo shop;
    private long pid;
    private int state;
    private LocalDateTime confirmTime;
    private Long originPrice;
    private Long discountPrice;
    private Long expressFee;
    private Long point;
    private String message;
    private Long regionId;
    private String address;
    private String mobile;
    private String consignee;
    private Long grouponId;
    private Long advancesaleId;
    private String shipmentSn;
    private AfterSaleOrderItemRetVo orderItems;

    public AfterSaleOrderRetVo(Order order, AfterSaleOrderItemRetVo orderItem){
        this.id = order.getId();
        this.orderSn = order.getOrderSn();
        this.pid = 0;
        this.state = order.getState();
        this.confirmTime = order.getConfirmTime();
        this.originPrice = order.getOriginPrice();
        this.discountPrice = order.getDiscountPrice();
        this.expressFee = order.getExpressFee();
        this.point = order.getPoint();
        this.message = order.getMessage();
        this.regionId = order.getRegionId();
        this.address = order.getAddress();
        this.mobile = order.getMobile();
        this.consignee = order.getConsignee();
        this.grouponId = order.getGrouponId();
        this.advancesaleId = order.getAdvancesaleId();
        this.shipmentSn = order.getShipmentSn();
        this.orderItems = orderItem;
    }

    @Override
    public Object createVo() {
        return null;
    }

    @Override
    public Object createSimpleVo() {
        return null;
    }
}
